package csd.wyaiyr.com.config;

import lombok.Data;

@Data
public class BusinessException extends RuntimeException {

    private Integer code;

    private String errMsg;

//    通过状态码和错误消息创建异常对象

    public BusinessException(Integer code, String message) {
        super(message);
        this.code = code;
    }

    public BusinessException(String message) {
        super(message);
        this.code = code;
    }

}
